Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement geometry cache #1515

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

VReaperV
Copy link
Contributor

@VReaperV VReaperV commented Jan 22, 2025

Requires #1511, #1513, and #1514.

The geometry cache represents 3 buffers: a VBO, IBO, and inputVBO. These buffers will replace the old separate input VBOs and IBOs when enabled. This allows binding only a VAO before rendering, rather than setting up vertex pointers with the correct offset and formats every time. Additionally, it means that there's no need to switch between different VBOs/IBOs. The inputVBO is currently unused, but it will be needed to make models work with the geometry cache (model animations and world transform will be processed in a compute shader).

This further improves performance and removes the VBO/IBO check for materials.

Currently this is only used by the material system, but it should be possible to make the core renderer use it as well.

This will also be required to support entities with material system.

@VReaperV VReaperV added T-Improvement Improvement for an existing feature A-Renderer T-Feature-Request Proposed new feature T-Performance labels Jan 22, 2025
@VReaperV VReaperV force-pushed the geometry-cache branch 8 times, most recently from 299a185 to 07571fd Compare January 27, 2025 16:34
@VReaperV VReaperV force-pushed the geometry-cache branch 3 times, most recently from d58bd41 to 60407b8 Compare January 29, 2025 10:38
The geometry cache represents 3 buffers: a VBO, IBO, and inputVBO. These buffers will replace the old separate input VBOs and IBOs when enabled. This allows binding only a VAO before rendering, rather than setting up vertex pointers with the correct offset and formats every time. Additionally, it means that there's no need to switch between different VBOs/IBOs. The `inputVBO` is currently unused, but it will be needed to make models work with the geometry cache (model animations and world transform will be processed in a compute shader).

Currently this is only used by the material system, but it should be possible to make the core renderer use it as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Renderer T-Feature-Request Proposed new feature T-Improvement Improvement for an existing feature T-Performance
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

1 participant